#!/usr/local/bin/perl

if (!@ARGV){
   @ARGV = <STDIN>;
   chomp(@ARGV);
}

foreach $line1 (@ARGV){
    foreach $line2 (@ARGV){
        if ($line1 !~ /$line2/){
            $one=$line1;
            $line2 =~ /([^:]*)/ and $two=$1;
            print $one." ".$two."\n";
        }
    }
}

